home *** CD-ROM | disk | FTP | other *** search
/ kermit.columbia.edu / kermit.columbia.edu.tar / kermit.columbia.edu / newsgroups / misc.20030409-20031118 / 000041_jaltman2@nyc.rr.com_Thu May 1 17:33:28 EDT 2003.msg < prev    next >
Text File  |  2003-11-18  |  3KB  |  69 lines

  1. Article: 14256 of comp.protocols.kermit.misc
  2. Path: newsmaster.cc.columbia.edu!phl-feed.news.verio.net!iad-feed.news.verio.net!iad-peer.news.verio.net!news.verio.net!news.maxwell.syr.edu!newsfeed-east.nntpserver.com!nntpserver.com!news-west.rr.com!news-server.columbus.rr.com!cyclone.rdc-nyc.rr.com!news-out.nyc.rr.com!twister.nyc.rr.com.POSTED!53ab2750!not-for-mail
  3. Message-ID: <3EB182CB.8000502@nyc.rr.com>
  4. From: "Jeffrey Altman [Road Runner NYC]" <jaltman2@nyc.rr.com>
  5. User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312
  6. X-Accept-Language: en-us, en
  7. MIME-Version: 1.0
  8. Newsgroups: comp.protocols.kermit.misc
  9. Subject: Re: Changed behavior of receive/transmit move-to
  10. References: <b8rfll$kfv$1@cpimail.cpicorp.com> <b8rkdi$mo0$1@watsol.cc.columbia.edu>
  11. In-Reply-To: <b8rkdi$mo0$1@watsol.cc.columbia.edu>
  12. Content-Type: text/plain; charset=us-ascii; format=flowed
  13. Content-Transfer-Encoding: 7bit
  14. Lines: 46
  15. Date: Thu, 01 May 2003 20:25:50 GMT
  16. NNTP-Posting-Host: 66.108.138.151
  17. X-Complaints-To: abuse@rr.com
  18. X-Trace: twister.nyc.rr.com 1051820750 66.108.138.151 (Thu, 01 May 2003 16:25:50 EDT)
  19. NNTP-Posting-Date: Thu, 01 May 2003 16:25:50 EDT
  20. Organization: Road Runner - NYC
  21. Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:14256
  22.  
  23. Frank da Cruz wrote:
  24. > I would venture to say that the behavior you were relying on was not
  25. > intentional.  Although my notes don't show it, I suspect that somebody else
  26. > -- maybe even me -- was surprised when a relative directory name was not
  27. > resolved in the context in which the command was given, especially since
  28. > after changing contexts it might not be be valid.
  29.  
  30. Actually the person who initiated the original complaint about the
  31. unpredictable behavior of the SET ... MOVE-TO command was Derek.  We had
  32. quite a long discussion about this with him just after the New Year 2003.
  33.  
  34. There were several issues:
  35.  
  36.   * a SET command that accepts out output directory will fail if the
  37.     directory does not exist when the command is executed.  Otherwise
  38.     the command will fail.
  39.  
  40.   * what should happen if the relative MOVE-TO directory does not exist
  41.     at the time of the move?
  42.  
  43.     - Should the file transfer fail?  I think so.
  44.  
  45.     - Should the directory be created on the fly?  Some people
  46.       might want this option.
  47.  
  48.     - Should the move only take place if the relative directory exists?
  49.       Others might prefer this choice.
  50.  
  51. The concern I have with Frank's approach is that it is going to break
  52. existing scripts by adding another layer of string evaluation.  On 
  53. Windows this is going to become an even greater nightmare.
  54.  
  55. I think there is a better solution.  Kermit already supports on_open, 
  56. on_close, and on_exit macros.  I propose that we simply add support for 
  57. a new on_cd macro which would be executed whenever a the current working
  58. directory changes.  Then the macro can be defined to do the right thing:
  59.  
  60. define on_cd {
  61.    if = \fdirectories(<path>) 0 mkdir <path>
  62.    set send move-to <path>
  63.    set receive move-to <path>
  64. }
  65.  
  66. This allows the interpretation of the MOVE-TO path to remain fixed while
  67. providing the flexibility that Derek requires to get his job done.
  68.  
  69.